package com.gjy.disruptor.db2;

import com.lmax.disruptor.EventTranslator;

/**
 * @author gjy
 * @version 1.0
 * @since 2025-10-24 20:34:31
 */
public class UserAttentionTranslator implements EventTranslator<UserAttentionEntity> {

    private final UserAttentionEntity userAttentionEntity;

    public UserAttentionTranslator(UserAttentionEntity userAttentionEntity) {
        this.userAttentionEntity = userAttentionEntity;
    }

    @Override
    public void translateTo(UserAttentionEntity event, long sequence) {
        event.setUaId(userAttentionEntity.getUaId());
        event.setUserId(userAttentionEntity.getUserId());
        event.setUserAttentionId(userAttentionEntity.getUserAttentionId());
    }

}
